package zhxt.helmet.pojo;

import java.util.Date;
import java.time.Instant;
import java.time.LocalDate;
import java.time.ZoneId;

//历史结果
public class Result {
    private int id;
    private int cameraId;
    private Date detectTime;
    private Boolean haveHelmet;

    public int getId() {
        return id;
    }
    public void setId(int id) {
        this.id = id;
    }
    public int getCameraId() {
        return cameraId;
    }
    public void setCameraId(int cameraId) {
        this.cameraId = cameraId;
    }
    public Date getDetectTime() {
        return detectTime;
    }
    public LocalDate getLocalDate() {//获取日期
        return detectTime.toInstant()
                .atZone(ZoneId.systemDefault())
                .toLocalDate();
    }
    public void setDetectTime(Date detectTime) {
        this.detectTime = detectTime;
    }
    public Boolean getHaveHelmet() {
        return haveHelmet;
    }
    public void setHaveHelmet(Boolean haveHelmet) {
        this.haveHelmet = haveHelmet;
    }

}
